package com.et114.modules.msg.dao;

import com.et114.components.simpletable.DataList;
import com.et114.components.simpletable.dao.SimpleTableDAOImpl;
import com.et114.modules.msg.vo.MsgVO;

/**
 * @author zhiweip
 * @version 1.0
 * @created 16-十二月-2010 13:51:41
 */
public class Pub_MessageDaoImp  extends SimpleTableDAOImpl implements IPub_MessageDao {

	public Pub_MessageDaoImp(){

	}

	public void finalize() throws Throwable {

	}

	/**
	 * 
	 * @param vo
	 * @throws Exception 
	 */
	public DataList queryMsgDataList(MsgVO vo) throws Exception{
		return this.queryListDataList ( vo , "query_PUB_MESSAGEDataList" );
	}

	/**
	 * 
	 * @param vo
	 */
	public Integer insertMsgInfo(MsgVO vo){
		return (Integer)this.insert ( vo , "insert_PUB_MESSAGE" );
	}

	/**
	 * 
	 * @param vo
	 */
	public int updateMsgInfo(MsgVO vo){
		return this.update ( vo , "update_PUB_MESSAGE" );
	}
	
	public MsgVO loadMsg(MsgVO vo){
		Object o=this.load ( vo , "loadPub_message");
		if(o==null)return null;
		return (MsgVO)o;
	}
	
	public Long countNoread_PUB_MESSAGE(MsgVO vo){
		return  this.getCount ( vo , "countNoread_PUB_MESSAGE" );
	}

}